
<!DOCTYPE HTML>
<html lang="" >
    <head>
        <meta charset="UTF-8">
        <meta content="text/html; charset=utf-8" http-equiv="Content-Type">
        <title>Java注解 · tgor note</title>
        <meta http-equiv="X-UA-Compatible" content="IE=edge" />
        <meta name="description" content="">
        <meta name="generator" content="GitBook 3.2.3">
        <meta name="author" content="tgor">
        
        
    
    <link rel="stylesheet" href="../gitbook/style.css">

    
            
                
                <link rel="stylesheet" href="../gitbook/gitbook-plugin-chapter-fold/chapter-fold.css">
                
            
                
                <link rel="stylesheet" href="../gitbook/gitbook-plugin-splitter/splitter.css">
                
            
                
                <link rel="stylesheet" href="../gitbook/gitbook-plugin-tbfed-pagefooter/footer.css">
                
            
                
                <link rel="stylesheet" href="../gitbook/gitbook-plugin-page-toc-button/plugin.css">
                
            
                
                <link rel="stylesheet" href="../gitbook/gitbook-plugin-search-pro/search.css">
                
            
                
                <link rel="stylesheet" href="../gitbook/gitbook-plugin-back-to-top-button/plugin.css">
                
            
                
                <link rel="stylesheet" href="../gitbook/gitbook-plugin-code/plugin.css">
                
            
                
                <link rel="stylesheet" href="../gitbook/gitbook-plugin-highlight/website.css">
                
            
                
                <link rel="stylesheet" href="../gitbook/gitbook-plugin-fontsettings/website.css">
                
            
        

    

    
        
    
        
    
        
    
        
    
        
    
        
    

        
    
    
    <meta name="HandheldFriendly" content="true"/>
    <meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no">
    <meta name="apple-mobile-web-app-capable" content="yes">
    <meta name="apple-mobile-web-app-status-bar-style" content="black">
    <link rel="apple-touch-icon-precomposed" sizes="152x152" href="../gitbook/images/apple-touch-icon-precomposed-152.png">
    <link rel="shortcut icon" href="../gitbook/images/favicon.ico" type="image/x-icon">

    
    <link rel="next" href="Timsort排序算法.html" />
    
    
    <link rel="prev" href="HashMap源码分析.html" />
    

    </head>
    <body>
        
<div class="book">
    <div class="book-summary">
        
            
<div id="book-search-input" role="search">
    <input type="text" placeholder="Type to search" />
</div>

            
                <nav role="navigation">
                


<ul class="summary">
    
    

    

    
        
        
    
        <li class="chapter " data-level="1.1" data-path="../">
            
                <a href="../">
            
                    
                    Me
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.2" data-path="../category/微服务.html">
            
                <a href="../category/微服务.html">
            
                    
                    微服务
            
                </a>
            

            
            <ul class="articles">
                
    
        <li class="chapter " data-level="1.2.1" data-path="../Java-Spring/Feign.html">
            
                <a href="../Java-Spring/Feign.html">
            
                    
                    HTTP客户端Feign
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.2.2" data-path="../Java-其他库/限流.html">
            
                <a href="../Java-其他库/限流.html">
            
                    
                    限流
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.2.3" data-path="../运维/Nginx限流.html">
            
                <a href="../运维/Nginx限流.html">
            
                    
                    限流Nginx
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.2.4" data-path="../Java-Spring/负载均衡.html">
            
                <a href="../Java-Spring/负载均衡.html">
            
                    
                    负载均衡
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.2.5" data-path="../运维/Nginx负载均衡.html">
            
                <a href="../运维/Nginx负载均衡.html">
            
                    
                    负载均衡Nginx
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.2.6" data-path="../Java-其他库/熔断Hystrix.html">
            
                <a href="../Java-其他库/熔断Hystrix.html">
            
                    
                    熔断Hystrix
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.2.7" data-path="../Java-其他库/缓存.html">
            
                <a href="../Java-其他库/缓存.html">
            
                    
                    缓存
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.2.8" data-path="../Java-其他库/缓存.html">
            
                <a href="../Java-其他库/缓存.html#本地缓存">
            
                    
                    本地缓存
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.2.9" data-path="../Redis/Redis.html">
            
                <a href="../Redis/Redis.html">
            
                    
                    分布式缓存Redis
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.2.10" data-path="../Java-其他库/分布式事务.html">
            
                <a href="../Java-其他库/分布式事务.html">
            
                    
                    分布式事务
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.2.11" data-path="../Java-其他库/分布式事务.html">
            
                <a href="../Java-其他库/分布式事务.html#事务消息">
            
                    
                    可靠事务消息
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.2.12" data-path="../Java-Spring/业务监控.html">
            
                <a href="../Java-Spring/业务监控.html">
            
                    
                    业务监控
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.2.13" data-path="../Java-其他库/分布式定时作业.html">
            
                <a href="../Java-其他库/分布式定时作业.html">
            
                    
                    分布式作业调度ElasticJob
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.2.14" data-path="../Java-ORM/ORM.html">
            
                <a href="../Java-ORM/ORM.html">
            
                    
                    ORM
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.2.15" data-path="../Java-其他库/分布式系统及CAP原理.html">
            
                <a href="../Java-其他库/分布式系统及CAP原理.html">
            
                    
                    分布式系统及CAP原理
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.2.16" data-path="../MQ/RabbitMQ笔记.html">
            
                <a href="../MQ/RabbitMQ笔记.html">
            
                    
                    消息驱动Rabbitmq
            
                </a>
            

            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="1.3" data-path="../category/数据库.html">
            
                <a href="../category/数据库.html">
            
                    
                    数据库
            
                </a>
            

            
            <ul class="articles">
                
    
        <li class="chapter " data-level="1.3.1" data-path="../Mysql/经典数据库设计案例.html">
            
                <a href="../Mysql/经典数据库设计案例.html">
            
                    
                    mysql设计
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.3.2" data-path="../Mysql/Mysql事务与锁.html">
            
                <a href="../Mysql/Mysql事务与锁.html">
            
                    
                    mysql事务与锁
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.3.3" data-path="../Mysql/mysql数据类型.html">
            
                <a href="../Mysql/mysql数据类型.html">
            
                    
                    mysql数据类型
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.3.4" data-path="../Mysql/mysql索引及查询.html">
            
                <a href="../Mysql/mysql索引及查询.html">
            
                    
                    mysql索引与查询
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.3.5" data-path="../Mysql/mysql索引及查询.html">
            
                <a href="../Mysql/mysql索引及查询.html#查询语句设计准则">
            
                    
                    mysql查询语句设计准则
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.3.6" data-path="../Mysql/mysql性能测试.html">
            
                <a href="../Mysql/mysql性能测试.html">
            
                    
                    mysql性能测试
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.3.7" data-path="../Mysql/mysql主从同步与读写分离.html">
            
                <a href="../Mysql/mysql主从同步与读写分离.html">
            
                    
                    mysql主从同步与读写分离
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.3.8" data-path="../Java-Spring/SpringBoot事务注解@Transactional.html">
            
                <a href="../Java-Spring/SpringBoot事务注解@Transactional.html">
            
                    
                    Spring事务注解@Transactional
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.3.9" data-path="../数据结构与算法/位运算应用实例.html">
            
                <a href="../数据结构与算法/位运算应用实例.html">
            
                    
                    位运算应用实例
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.3.10" data-path="../Mongodb-Client/morphia-API汇总.html">
            
                <a href="../Mongodb-Client/morphia-API汇总.html">
            
                    
                    morphia API汇总
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.3.11" data-path="../Mongodb-Client/mongo驱动连接.html">
            
                <a href="../Mongodb-Client/mongo驱动连接.html">
            
                    
                    mongodb驱动与连接
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.3.12" data-path="../Mongodb/mongodb-ObjectId实践.html">
            
                <a href="../Mongodb/mongodb-ObjectId实践.html">
            
                    
                    mongodb ObjectId实践
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.3.13" data-path="../Mongodb/mongodb角色权限.html">
            
                <a href="../Mongodb/mongodb角色权限.html">
            
                    
                    mongodb角色权限
            
                </a>
            

            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="1.4" data-path="../category/java并发.html">
            
                <a href="../category/java并发.html">
            
                    
                    Java并发
            
                </a>
            

            
            <ul class="articles">
                
    
        <li class="chapter " data-level="1.4.1" data-path="Java并发.html">
            
                <a href="Java并发.html">
            
                    
                    Java并发
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.4.2" data-path="Java并发.html">
            
                <a href="Java并发.html#锁">
            
                    
                    Java并发之锁设计
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.4.3" data-path="Java并发.html">
            
                <a href="Java并发.html#synchronized">
            
                    
                    Java并发之synchronized
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.4.4" data-path="Java之Lock.html">
            
                <a href="Java之Lock.html#reentrantlock">
            
                    
                    Java Lock之ReentrantLock
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.4.5" data-path="Java之Lock.html">
            
                <a href="Java之Lock.html#reentrantreadwritelock">
            
                    
                    Java Lock之ReentrantReadWriteLock
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.4.6" data-path="Java之Future.html">
            
                <a href="Java之Future.html">
            
                    
                    Java Future
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.4.7" data-path="Java之Future.html">
            
                <a href="Java之Future.html#futuretask">
            
                    
                    Java Future之FutureTask
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.4.8" data-path="Java之Future.html">
            
                <a href="Java之Future.html#completablefuture">
            
                    
                    Java Future之CompletableFuture
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.4.9" data-path="Java之Future.html">
            
                <a href="Java之Future.html#forkjointask">
            
                    
                    Java Future之ForkJoinTask
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.4.10" data-path="Java之Thread.html">
            
                <a href="Java之Thread.html">
            
                    
                    Java Thread
            
                </a>
            

            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="1.5" data-path="../category/redis.html">
            
                <a href="../category/redis.html">
            
                    
                    Redis
            
                </a>
            

            
            <ul class="articles">
                
    
        <li class="chapter " data-level="1.5.1" data-path="../Redis/Redis.html">
            
                <a href="../Redis/Redis.html">
            
                    
                    Redis
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.5.2" data-path="../Redis/Redis.html">
            
                <a href="../Redis/Redis.html#集群">
            
                    
                    Redis集群
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.5.3" data-path="../Redis/Redis.html">
            
                <a href="../Redis/Redis.html#消息订阅">
            
                    
                    Redis消息订阅
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.5.4" data-path="../Redis/Redis.html">
            
                <a href="../Redis/Redis.html#lua">
            
                    
                    Redis Lua脚本
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.5.5" data-path="../Redis/Redis.html">
            
                <a href="../Redis/Redis.html#配置汇总">
            
                    
                    Redis配置汇总
            
                </a>
            

            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="1.6" data-path="../category/运维.html">
            
                <a href="../category/运维.html">
            
                    
                    运维
            
                </a>
            

            
            <ul class="articles">
                
    
        <li class="chapter " data-level="1.6.1" data-path="../运维/Linux常用操作汇总.html">
            
                <a href="../运维/Linux常用操作汇总.html">
            
                    
                    Linux常用操作汇总
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.6.2" data-path="../运维/阿里云笔记.html">
            
                <a href="../运维/阿里云笔记.html">
            
                    
                    阿里云笔记
            
                </a>
            

            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="1.7" data-path="../category/nginx.html">
            
                <a href="../category/nginx.html">
            
                    
                    Nginx
            
                </a>
            

            
            <ul class="articles">
                
    
        <li class="chapter " data-level="1.7.1" data-path="../运维/Nginx学习笔记.html">
            
                <a href="../运维/Nginx学习笔记.html">
            
                    
                    Nginx基础
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.7.2" data-path="../运维/Nginx负载均衡.html">
            
                <a href="../运维/Nginx负载均衡.html">
            
                    
                    Nginx负载均衡
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.7.3" data-path="../运维/Nginx限流.html">
            
                <a href="../运维/Nginx限流.html">
            
                    
                    Nginx限流
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.7.4" data-path="../运维/Nginx学习笔记.html">
            
                <a href="../运维/Nginx学习笔记.html#六、其他">
            
                    
                    Nginx客户端辅助技巧
            
                </a>
            

            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="1.8" data-path="../category/容器化.html">
            
                <a href="../category/容器化.html">
            
                    
                    容器化
            
                </a>
            

            
            <ul class="articles">
                
    
        <li class="chapter " data-level="1.8.1" data-path="../Docker/docker笔记.html">
            
                <a href="../Docker/docker笔记.html">
            
                    
                    Docker学习笔记
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.8.2" data-path="../Docker/docker笔记.html">
            
                <a href="../Docker/docker笔记.html#基础操作">
            
                    
                    Docker基础操作
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.8.3" data-path="../Docker/docker笔记.html">
            
                <a href="../Docker/docker笔记.html#dockerfile">
            
                    
                    DockerFile
            
                </a>
            

            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="1.9" data-path="../category/Web.html">
            
                <a href="../category/Web.html">
            
                    
                    Web
            
                </a>
            

            
            <ul class="articles">
                
    
        <li class="chapter " data-level="1.9.1" data-path="../运维/Http入坑Https笔记.html">
            
                <a href="../运维/Http入坑Https笔记.html">
            
                    
                    Http入坑Https笔记
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.9.2" data-path="../Web/阿里云OSS.html">
            
                <a href="../Web/阿里云OSS.html">
            
                    
                    OSS
            
                </a>
            

            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="1.10" data-path="../category/java基础.html">
            
                <a href="../category/java基础.html">
            
                    
                    Java基础
            
                </a>
            

            
            <ul class="articles">
                
    
        <li class="chapter " data-level="1.10.1" data-path="Java基础.html">
            
                <a href="Java基础.html#jvm">
            
                    
                    JVM基础
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.10.2" data-path="Java基础.html">
            
                <a href="Java基础.html#语法糖">
            
                    
                    Java语法糖
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.10.3" data-path="Java基础.html">
            
                <a href="Java基础.html#数据结构">
            
                    
                    Java数据结构
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.10.4" data-path="Java8函数式编程.html">
            
                <a href="Java8函数式编程.html">
            
                    
                    java8函数式编程
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.10.5" data-path="ArrayList源码分析.html">
            
                <a href="ArrayList源码分析.html">
            
                    
                    JDK源码分析ArrayList
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.10.6" data-path="HashMap源码分析.html">
            
                <a href="HashMap源码分析.html">
            
                    
                    JDK源码分析HashMap
            
                </a>
            

            
        </li>
    
        <li class="chapter active" data-level="1.10.7" data-path="Java注解.html">
            
                <a href="Java注解.html">
            
                    
                    Java注解
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.10.8" data-path="Timsort排序算法.html">
            
                <a href="Timsort排序算法.html">
            
                    
                    Timsort排序算法
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.10.9" data-path="插入排序分析与Java实现.html">
            
                <a href="插入排序分析与Java实现.html">
            
                    
                    插入排序分析与Java实现
            
                </a>
            

            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="1.11" data-path="../category/工具与规范.html">
            
                <a href="../category/工具与规范.html">
            
                    
                    工具与规范
            
                </a>
            

            
            <ul class="articles">
                
    
        <li class="chapter " data-level="1.11.1" data-path="../工具/Maven使用技巧汇总.html">
            
                <a href="../工具/Maven使用技巧汇总.html">
            
                    
                    Maven使用技巧
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.11.2" data-path="../编码规范/Java编码规范.html">
            
                <a href="../编码规范/Java编码规范.html">
            
                    
                    Java编码规范
            
                </a>
            

            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="1.12" data-path="../category/OLAP.html">
            
                <a href="../category/OLAP.html">
            
                    
                    OLAP
            
                </a>
            

            
            <ul class="articles">
                
    
        <li class="chapter " data-level="1.12.1" data-path="../数据处理/storm学习笔记.html">
            
                <a href="../数据处理/storm学习笔记.html">
            
                    
                    流式计算Storm学习笔记
            
                </a>
            

            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="1.13" data-path="../category/数据运营.html">
            
                <a href="../category/数据运营.html">
            
                    
                    数据运营
            
                </a>
            

            
            <ul class="articles">
                
    
        <li class="chapter " data-level="1.13.1" data-path="../数据运营/增长黑客数据运营.html">
            
                <a href="../数据运营/增长黑客数据运营.html">
            
                    
                    增长黑客-数据运营
            
                </a>
            

            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="1.14" data-path="../category/前端技术栈.html">
            
                <a href="../category/前端技术栈.html">
            
                    
                    前端技术栈
            
                </a>
            

            
            <ul class="articles">
                
    
        <li class="chapter " data-level="1.14.1" data-path="../前端/JavaScript设计模式.html">
            
                <a href="../前端/JavaScript设计模式.html">
            
                    
                    JavaScript设计模式
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.14.2" data-path="../前端/html相对路径与绝对路径.html">
            
                <a href="../前端/html相对路径与绝对路径.html">
            
                    
                    Html相对路径与绝对路径
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.14.3" data-path="../前端/微信小程序学习笔记.html">
            
                <a href="../前端/微信小程序学习笔记.html">
            
                    
                    微信小程序学习笔记
            
                </a>
            

            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="1.15" data-path="../category/个人.html">
            
                <a href="../category/个人.html">
            
                    
                    个人
            
                </a>
            

            
            <ul class="articles">
                
    
        <li class="chapter " data-level="1.15.1" data-path="../个人/简历.html">
            
                <a href="../个人/简历.html">
            
                    
                    简历
            
                </a>
            

            
        </li>
    

            </ul>
            
        </li>
    

    

    <li class="divider"></li>

    <li>
        <a href="https://www.gitbook.com" target="blank" class="gitbook-link">
            Published with GitBook
        </a>
    </li>
</ul>


                </nav>
            
        
    </div>

    <div class="book-body">
        
            <div class="body-inner">
                
                    

<div class="book-header" role="navigation">
    

    <!-- Title -->
    <h1>
        <i class="fa fa-circle-o-notch fa-spin"></i>
        <a href=".." >Java注解</a>
    </h1>
</div>




                    <div class="page-wrapper" tabindex="-1" role="main">
                        <div class="page-inner">
                            
<div id="book-search-results">
    <div class="search-noresults">
    
                                <section class="normal markdown-section">
                                
                                <h1 id="java&#x6CE8;&#x89E3;">Java&#x6CE8;&#x89E3;</h1>
<p>&#x6807;&#x7B7E;&#xFF08;&#x7A7A;&#x683C;&#x5206;&#x9694;&#xFF09;&#xFF1A; Java-Base</p>
<hr>
<h2 id="&#x4E00;&#x3001;&#x5185;&#x7F6E;&#x6CE8;&#x89E3;">&#x4E00;&#x3001;&#x5185;&#x7F6E;&#x6CE8;&#x89E3;</h2>
<p>&#x6CE8;&#x89E3;&#x7684;&#x57FA;&#x7840;&#x6982;&#x5FF5;&#xFF1A;&#x5F15;&#x7528;&#x81EA;&#xFF1A;<a href="http://blog.csdn.net/doc_sgl/article/details/50367083" target="_blank">&#x81EA;&#x5DF1;&#x52A8;&#x624B;&#x5B9E;&#x73B0;Java&#x6CE8;&#x89E3;&#xFF08;Java Annotation in Action&#xFF09;</a></p>
<p>Java&#x6CE8;&#x89E3;&#x662F;&#x9644;&#x52A0;&#x5728;&#x4EE3;&#x7801;&#x4E2D;&#x7684;&#x4E00;&#x4E9B;&#x5143;&#x4FE1;&#x606F;&#xFF0C;&#x7528;&#x4E8E;&#x7F16;&#x8BD1;&#x548C;&#x8FD0;&#x884C;&#x65F6;&#x8FDB;&#x884C;&#x89E3;&#x6790;&#x548C;&#x4F7F;&#x7528;&#xFF0C;&#x8D77;&#x5230;&#x8BF4;&#x660E;&#x3001;&#x914D;&#x7F6E;&#x7684;&#x529F;&#x80FD;&#x3002;&#x6CE8;&#x89E3;&#x4E0D;&#x4F1A;&#x5F71;&#x54CD;&#x4EE3;&#x7801;&#x7684;&#x5B9E;&#x9645;&#x903B;&#x8F91;&#xFF0C;&#x4EC5;&#x4EC5;&#x8D77;&#x5230;&#x8F85;&#x52A9;&#x6027;&#x7684;&#x4F5C;&#x7528;&#x3002;&#x5305;&#x542B;&#x5728;<code>java.lang.annotation</code>&#x5305;&#x4E2D;&#x3002;&#x6CE8;&#x89E3;&#x7684;&#x5B9A;&#x4E49;&#x7C7B;&#x4F3C;&#x4E8E;&#x63A5;&#x53E3;&#x7684;&#x5B9A;&#x4E49;&#xFF0C;&#x4F7F;&#x7528;@interface&#x6765;&#x5B9A;&#x4E49;&#xFF0C;&#x5B9A;&#x4E49;&#x4E00;&#x4E2A;&#x65B9;&#x6CD5;&#x5373;&#x4E3A;&#x6CE8;&#x89E3;&#x7C7B;&#x578B;&#x5B9A;&#x4E49;&#x4E86;&#x4E00;&#x4E2A;&#x5143;&#x7D20;&#xFF0C;<strong>&#x65B9;&#x6CD5;&#x7684;&#x58F0;&#x660E;&#x4E0D;&#x5141;&#x8BB8;&#x6709;&#x53C2;&#x6570;&#x6216;throw&#x8BED;&#x53E5;</strong>&#xFF0C;<strong>&#x8FD4;&#x56DE;&#x503C;&#x7C7B;&#x578B;&#x88AB;&#x9650;&#x5B9A;&#x4E3A;&#x539F;&#x59CB;&#x6570;&#x636E;&#x7C7B;&#x578B;</strong>&#x3001;&#x5B57;&#x7B26;&#x4E32;String&#x3001;Class&#x3001;enums&#x3001;&#x6CE8;&#x89E3;&#x7C7B;&#x578B;&#xFF0C;&#x6216;&#x524D;&#x9762;&#x8FD9;&#x4E9B;&#x7684;&#x6570;&#x7EC4;&#xFF0C;&#x65B9;&#x6CD5;&#x53EF;&#x4EE5;&#x6709;&#x9ED8;&#x8BA4;&#x503C;&#x3002;&#x6CE8;&#x89E3;&#x5E76;&#x4E0D;&#x76F4;&#x63A5;&#x5F71;&#x54CD;&#x4EE3;&#x7801;&#x7684;&#x8BED;&#x4E49;&#xFF0C;&#x4F46;&#x662F;&#x4ED6;&#x53EF;&#x4EE5;&#x88AB;&#x770B;&#x505A;&#x662F;&#x7A0B;&#x5E8F;&#x7684;&#x5DE5;&#x5177;&#x6216;&#x8005;&#x7C7B;&#x5E93;&#x3002;&#x5B83;&#x4F1A;&#x53CD;&#x8FC7;&#x6765;&#x5BF9;&#x6B63;&#x5728;&#x8FD0;&#x884C;&#x7684;&#x7A0B;&#x5E8F;&#x8BED;&#x4E49;&#x6709;&#x6240;&#x5F71;&#x54CD;&#x3002;&#x6CE8;&#x89E3;&#x53EF;&#x4EE5;&#x4ECE;&#x6E90;&#x6587;&#x4EF6;&#x3001;class&#x6587;&#x4EF6;&#x6216;&#x8005;&#x5728;&#x8FD0;&#x884C;&#x65F6;&#x901A;&#x8FC7;&#x53CD;&#x5C04;&#x673A;&#x5236;&#x591A;&#x79CD;&#x65B9;&#x5F0F;&#x88AB;&#x8BFB;&#x53D6;&#x3002;</p>
<p>&#x5E38;&#x7528;&#x5185;&#x7F6E;&#x6CE8;&#x89E3;&#x6709;&#x4EE5;&#x4E0B;&#xFF1A;</p>
<ol>
<li><code>@interface</code>&#xFF1A; &#x4F7F;&#x7528;@interface&#x5B9A;&#x4E49;&#x6CE8;&#x89E3;&#x65F6;&#xFF0C;&#x610F;&#x5473;&#x7740;&#x5B83;&#x5B9E;&#x73B0;&#x4E86;java.lang.annotation.Annotation&#x63A5;&#x53E3;&#xFF0C;&#x5373;&#x8BE5;&#x6CE8;&#x89E3;&#x5C31;&#x662F;&#x4E00;&#x4E2A;Annotation&#xFF1B;</li>
<li><code>@Inherited</code>&#xFF1A;&#x7236;&#x7C7B;&#x6807;&#x6CE8;&#x6B64;&#x6CE8;&#x89E3;&#xFF0C;&#x5B50;&#x7C7B;&#x62E5;&#x6709;&#x6B64;&#x6CE8;&#x89E3;&#x7279;&#x6027;&#xFF1B;</li>
<li><code>@Target</code>&#xFF1A;&#x9650;&#x5B9A;&#x6CE8;&#x89E3;&#x7684;&#x6807;&#x6CE8;&#x8303;&#x56F4;&#xFF0C;&#x8303;&#x56F4;&#x4E3A;<strong>ElementType</strong>&#x679A;&#x4E3E;&#x8303;&#x56F4;</li>
<li><code>@Retention</code>&#xFF1A;&#x6307;&#x5B9A;&#x6CE8;&#x89E3;&#x7684;&#x751F;&#x547D;&#x5468;&#x671F;&#x7B56;&#x7565;&#xFF0C;&#x8303;&#x56F4;&#x4E3A;<strong>RetentionPolicy</strong>&#x679A;&#x4E3E;&#x8303;&#x56F4;</li>
<li><code>@Deprecated</code>&#xFF1A;&#x6807;&#x6CE8;&#x6B64;&#x6CE8;&#x89E3;&#x7684;&#x6784;&#x9020;&#x5668;&#x3001;&#x5C5E;&#x6027;&#x3001;&#x53D8;&#x91CF;&#x3001;&#x65B9;&#x6CD5;&#x3001;&#x5305;&#x3001;&#x53C2;&#x6570;&#x3001;&#x7C7B;&#x578B;&#x4E3A;&#x5F03;&#x7528;&#x6216;&#x5EFA;&#x8BAE;&#x4E0D;&#x88AB;&#x4F7F;&#x7528;&#x7684;</li>
<li><code>@Override</code>&#xFF1A;&#x53EA;&#x80FD;&#x6807;&#x6CE8;&#x65B9;&#x6CD5;&#xFF0C;&#x8868;&#x793A;&#x8BE5;&#x65B9;&#x6CD5;&#x8986;&#x76D6;&#x7236;&#x7C7B;&#x4E2D;&#x7684;&#x65B9;&#x6CD5;</li>
<li><code>@SuppressWarnings</code>&#xFF1A;&#x6240;&#x6807;&#x6CE8;&#x5185;&#x5BB9;&#x4EA7;&#x751F;&#x7684;&#x8B66;&#x544A;&#xFF0C;&#x7F16;&#x8BD1;&#x5668;&#x4F1A;&#x5BF9;&#x8FD9;&#x4E9B;&#x8B66;&#x544A;&#x4FDD;&#x6301;&#x9759;&#x9ED8;</li>
</ol>
<p><strong>ElementType</strong>&#x8303;&#x56F4;&#x5982;&#x4E0B;&#xFF1A;</p>
<pre><code class="lang-java"><span class="hljs-keyword">package</span> java.lang.annotation;

<span class="hljs-keyword">public</span> <span class="hljs-keyword">enum</span> ElementType {
    TYPE,               <span class="hljs-comment">/* &#x7C7B;&#x3001;&#x63A5;&#x53E3;&#xFF08;&#x5305;&#x62EC;&#x6CE8;&#x91CA;&#x7C7B;&#x578B;&#xFF09;&#x6216;&#x679A;&#x4E3E;&#x58F0;&#x660E;  */</span>

    FIELD,              <span class="hljs-comment">/* &#x5B57;&#x6BB5;&#x58F0;&#x660E;&#xFF08;&#x5305;&#x62EC;&#x679A;&#x4E3E;&#x5E38;&#x91CF;&#xFF09;  */</span>

    METHOD,             <span class="hljs-comment">/* &#x65B9;&#x6CD5;&#x58F0;&#x660E;  */</span>

    PARAMETER,          <span class="hljs-comment">/* &#x53C2;&#x6570;&#x58F0;&#x660E;  */</span>

    CONSTRUCTOR,        <span class="hljs-comment">/* &#x6784;&#x9020;&#x65B9;&#x6CD5;&#x58F0;&#x660E;  */</span>

    LOCAL_VARIABLE,     <span class="hljs-comment">/* &#x5C40;&#x90E8;&#x53D8;&#x91CF;&#x58F0;&#x660E;  */</span>

    ANNOTATION_TYPE,    <span class="hljs-comment">/* &#x6CE8;&#x91CA;&#x7C7B;&#x578B;&#x58F0;&#x660E;  */</span>

    PACKAGE             <span class="hljs-comment">/* &#x5305;&#x58F0;&#x660E;  */</span>
}
</code></pre>
<p><strong>RetentionPolicy</strong>&#x679A;&#x4E3E;&#x8303;&#x56F4;&#x5982;&#x4E0B;&#xFF1A;</p>
<pre><code class="lang-java"><span class="hljs-keyword">package</span> java.lang.annotation;
<span class="hljs-keyword">public</span> <span class="hljs-keyword">enum</span> RetentionPolicy {
    SOURCE,            <span class="hljs-comment">/* Annotation&#x4FE1;&#x606F;&#x4EC5;&#x5B58;&#x5728;&#x4E8E;&#x7F16;&#x8BD1;&#x5668;&#x5904;&#x7406;&#x671F;&#x95F4;&#xFF0C;&#x7F16;&#x8BD1;&#x5668;&#x5904;&#x7406;&#x5B8C;&#x4E4B;&#x540E;&#x5C31;&#x6CA1;&#x6709;&#x8BE5;Annotation&#x4FE1;&#x606F;&#x4E86;  */</span>

    CLASS,             <span class="hljs-comment">/* &#x7F16;&#x8BD1;&#x5668;&#x5C06;Annotation&#x5B58;&#x50A8;&#x4E8E;&#x7C7B;&#x5BF9;&#x5E94;&#x7684;.class&#x6587;&#x4EF6;&#x4E2D;&#x3002;&#x9ED8;&#x8BA4;&#x884C;&#x4E3A;  */</span>

    RUNTIME            <span class="hljs-comment">/* &#x7F16;&#x8BD1;&#x5668;&#x5C06;Annotation&#x5B58;&#x50A8;&#x4E8E;class&#x6587;&#x4EF6;&#x4E2D;&#xFF0C;&#x5E76;&#x4E14;&#x53EF;&#x7531;JVM&#x8BFB;&#x5165; */</span>
}
</code></pre>
<hr>
<h2 id="&#x4E8C;&#x3001;&#x81EA;&#x5B9A;&#x4E49;&#x6CE8;&#x89E3;&#x5B9E;&#x73B0;">&#x4E8C;&#x3001;&#x81EA;&#x5B9A;&#x4E49;&#x6CE8;&#x89E3;&#x5B9E;&#x73B0;</h2>
<p>&#x81EA;&#x5B9A;&#x4E49;&#x6CE8;&#x89E3;&#x7C7B;&#x7F16;&#x5199;&#x7684;&#x4E00;&#x4E9B;&#x89C4;&#x5219;:</p>
<ol>
<li>Annotation&#x578B;&#x5B9A;&#x4E49;&#x4E3A;@interface&#xFF0C;&#x6240;&#x6709;&#x7684;Annotation&#x4F1A;&#x81EA;&#x52A8;&#x7EE7;&#x627F;java.lang.Annotation&#x8FD9;&#x4E00;&#x63A5;&#x53E3;,&#x5E76;&#x4E14;&#x4E0D;&#x80FD;&#x518D;&#x53BB;&#x7EE7;&#x627F;&#x522B;&#x7684;&#x7C7B;&#x6216;&#x662F;&#x63A5;&#x53E3;.</li>
<li>&#x53C2;&#x6570;&#x6210;&#x5458;&#x53EA;&#x80FD;&#x7528;public&#x6216;&#x9ED8;&#x8BA4;(default)&#x8FD9;&#x4E24;&#x4E2A;&#x8BBF;&#x95EE;&#x6743;&#x4FEE;&#x9970;</li>
<li>&#x53C2;&#x6570;&#x6210;&#x5458;&#x53EA;&#x80FD;&#x7528;&#x57FA;&#x672C;&#x7C7B;&#x578B;byte,short,char,int,long,float,double,boolean&#x516B;&#x79CD;&#x57FA;&#x672C;&#x6570;&#x636E;&#x7C7B;&#x578B;&#x548C;String&#x3001;Enum&#x3001;Class&#x3001;annotations&#x7B49;&#x6570;&#x636E;&#x7C7B;&#x578B;,&#x4EE5;&#x53CA;&#x8FD9;&#x4E00;&#x4E9B;&#x7C7B;&#x578B;&#x7684;&#x6570;&#x7EC4;.</li>
<li>&#x8981;&#x83B7;&#x53D6;&#x7C7B;&#x65B9;&#x6CD5;&#x548C;&#x5B57;&#x6BB5;&#x7684;&#x6CE8;&#x89E3;&#x4FE1;&#x606F;&#xFF0C;&#x5FC5;&#x987B;&#x901A;&#x8FC7;Java&#x7684;&#x53CD;&#x5C04;&#x6280;&#x672F;&#x6765;&#x83B7;&#x53D6; Annotation&#x5BF9;&#x8C61;,&#x56E0;&#x4E3A;&#x4F60;&#x9664;&#x6B64;&#x4E4B;&#x5916;&#x6CA1;&#x6709;&#x522B;&#x7684;&#x83B7;&#x53D6;&#x6CE8;&#x89E3;&#x5BF9;&#x8C61;&#x7684;&#x65B9;&#x6CD5;</li>
<li>&#x6CE8;&#x89E3;&#x4E5F;&#x53EF;&#x4EE5;&#x6CA1;&#x6709;&#x5B9A;&#x4E49;&#x6210;&#x5458;, &#x4E0D;&#x8FC7;&#x8FD9;&#x6837;&#x6CE8;&#x89E3;&#x5C31;&#x6CA1;&#x5565;&#x7528;&#x4E86;</li>
</ol>
<p><strong>PS</strong>:&#x81EA;&#x5B9A;&#x4E49;&#x6CE8;&#x89E3;&#x9700;&#x8981;&#x4F7F;&#x7528;&#x5230;&#x5143;&#x6CE8;&#x89E3;</p>
<p>&#x4F8B;&#x5B50;&#xFF1A;
&#x6CE8;&#x89E3;&#x7C7B;&#xFF1A;NameScanner.class</p>
<pre><code class="lang-java"><span class="hljs-meta">@Target</span>({ElementType.TYPE,
        ElementType.METHOD,
        ElementType.FIELD,
        ElementType.LOCAL_VARIABLE})
<span class="hljs-meta">@Retention</span>(RetentionPolicy.RUNTIME)
<span class="hljs-keyword">public</span> <span class="hljs-meta">@interface</span> NameScanner {
    <span class="hljs-function"><span class="hljs-keyword">public</span> String <span class="hljs-title">name</span><span class="hljs-params">()</span> <span class="hljs-keyword">default</span> &quot;&quot;</span>;
}
</code></pre>
<p>&#x89E3;&#x91CA;&#x5904;&#x7406;&#x5668;&#xFF1A;NameScannerProcessor2.class &#x626B;&#x63CF;&#x6807;&#x6CE8;&#x6CE8;&#x89E3;NameScanner&#x7684;&#x7C7B;&#x3001;&#x5B57;&#x6BB5;&#x3001;&#x65B9;&#x6CD5;&#x3001;&#x53D8;&#x91CF;&#xFF0C;&#x5982;&#x679C;&#x6CA1;&#x6709;&#x6807;&#x6CE8;&#x540D;&#x79F0;&#xFF0C;&#x5219;&#x6253;&#x5370;&#x9ED8;&#x8BA4;&#x540D;&#x79F0;</p>
<pre><code class="lang-java"><span class="hljs-keyword">public</span> <span class="hljs-class"><span class="hljs-keyword">class</span> <span class="hljs-title">NameScannerProcessor2</span> </span>{
    <span class="hljs-function"><span class="hljs-keyword">public</span> <span class="hljs-keyword">static</span> <span class="hljs-keyword">void</span> <span class="hljs-title">init</span><span class="hljs-params">(Class&lt;?&gt; clazz)</span> </span>{
        <span class="hljs-keyword">if</span> (clazz.isAnnotationPresent(NameScanner.class)) {
            <span class="hljs-comment">//&#x626B;&#x63CF;&#x7C7B;&#x578B;</span>
            print(<span class="hljs-string">&quot;type&quot;</span>, (NameScanner) clazz.getAnnotation(NameScanner.class), clazz.getName());

            <span class="hljs-comment">//&#x626B;&#x63CF;&#x5B57;&#x6BB5;</span>
            Field[] fields = clazz.getDeclaredFields();
            <span class="hljs-keyword">for</span> (Field field : fields) {
                <span class="hljs-keyword">if</span> (field.isAnnotationPresent(NameScanner.class)) {
                    print(<span class="hljs-string">&quot;field&quot;</span>, (NameScanner) field.getAnnotation(NameScanner.class), field.getName());
                }

            }

            <span class="hljs-comment">//&#x626B;&#x63CF;&#x51FD;&#x6570;</span>
            Method[] methods = clazz.getMethods();
            <span class="hljs-keyword">for</span> (Method method : methods) {
                <span class="hljs-keyword">if</span> (method.isAnnotationPresent(NameScanner.class)) {
                    print(<span class="hljs-string">&quot;method&quot;</span>, (NameScanner) method.getAnnotation(NameScanner.class), method.getName());
                }
            }
        }
    }

    <span class="hljs-function"><span class="hljs-keyword">private</span> <span class="hljs-keyword">static</span> <span class="hljs-keyword">void</span> <span class="hljs-title">print</span><span class="hljs-params">(String type, NameScanner scanner, String name)</span> </span>{
        name = !Strings.isNullOrEmpty(scanner.name()) ? scanner.name() : name;
        System.out.println(type + <span class="hljs-string">&quot; result:&quot;</span> + name);
    }
}
</code></pre>
<p>&#x6D4B;&#x8BD5;&#x7C7B;&#xFF1A;</p>
<pre><code class="lang-java">@NameScanner(name = &quot;name scanner test class&quot;)
public class NameScannerTest {
    @NameScanner(name = &quot;field name&quot;)
    private String name;

    @NameScanner
    private int age;

    @NameScanner(name = &quot;get name method&quot;)
    public String getName() {
        return this.name;
    }

    @NameScanner
    public void setName(String name) {
        this.name = name;
    }

    public static void main(String[] args) {
        NameScannerProcessor2.init(NameScannerTest.class);
        System.out.println(&quot;--finished--&quot;);
    }
}

output:
type result:name scanner test class
field result:field name
field result:age
method result:get name method
method result:setName
--finished--
</code></pre>
<hr>
<h2 id="&#x4E09;&#x3001;&#x5E38;&#x89C1;&#x6CE8;&#x89E3;">&#x4E09;&#x3001;&#x5E38;&#x89C1;&#x6CE8;&#x89E3;</h2>
<h3 id="1override">1.@Override</h3>
<pre><code>  java.lang.Override&#x662F;&#x4E00;&#x4E2A;&#x6807;&#x8BB0;&#x7C7B;&#x578B;&#x6CE8;&#x89E3;&#xFF0C;&#x5B83;&#x88AB;&#x7528;&#x4F5C;&#x6807;&#x6CE8;&#x65B9;&#x6CD5;&#x3002;&#x5B83;&#x8BF4;&#x660E;&#x4E86;&#x88AB;&#x6807;&#x6CE8;&#x7684;&#x65B9;&#x6CD5;&#x91CD;&#x8F7D;&#x4E86;&#x7236;&#x7C7B;&#x7684;&#x65B9;&#x6CD5;&#xFF0C;&#x8D77;&#x5230;&#x4E86;&#x65AD;&#x8A00;&#x7684;&#x4F5C;&#x7528;&#x3002;&#x5982;&#x679C;&#x6211;&#x4EEC;&#x4F7F;&#x7528;&#x4E86;&#x8FD9;&#x79CD;&#x6CE8;&#x89E3;&#x5728;&#x4E00;&#x4E2A;&#x6CA1;&#x6709;&#x8986;&#x76D6;&#x7236;&#x7C7B;&#x65B9;&#x6CD5;&#x7684;&#x65B9;&#x6CD5;&#x65F6;&#xFF0C;java&#x7F16;&#x8BD1;&#x5668;&#x5C06;&#x4EE5;&#x4E00;&#x4E2A;&#x7F16;&#x8BD1;&#x9519;&#x8BEF;&#x6765;&#x8B66;&#x793A;&#x3002;
</code></pre><h3 id="2deprecated">2.@Deprecated</h3>
<pre><code> Deprecated&#x4E5F;&#x662F;&#x4E00;&#x79CD;&#x6807;&#x8BB0;&#x7C7B;&#x578B;&#x6CE8;&#x89E3;&#x3002;&#x5F53;&#x4E00;&#x4E2A;&#x7C7B;&#x578B;&#x6216;&#x8005;&#x7C7B;&#x578B;&#x6210;&#x5458;&#x4F7F;&#x7528;@Deprecated&#x4FEE;&#x9970;&#x7684;&#x8BDD;&#xFF0C;&#x7F16;&#x8BD1;&#x5668;&#x5C06;&#x4E0D;&#x9F13;&#x52B1;&#x4F7F;&#x7528;&#x8FD9;&#x4E2A;&#x88AB;&#x6807;&#x6CE8;&#x7684;&#x7A0B;&#x5E8F;&#x5143;&#x7D20;&#x3002;&#x6240;&#x4EE5;&#x4F7F;&#x7528;&#x8FD9;&#x79CD;&#x4FEE;&#x9970;&#x5177;&#x6709;&#x4E00;&#x5B9A;&#x7684;&#x201C;&#x5EF6;&#x7EED;&#x6027;&#x201D;&#xFF1A;&#x5982;&#x679C;&#x6211;&#x4EEC;&#x5728;&#x4EE3;&#x7801;&#x4E2D;&#x901A;&#x8FC7;&#x7EE7;&#x627F;&#x6216;&#x8005;&#x8986;&#x76D6;&#x7684;&#x65B9;&#x5F0F;&#x4F7F;&#x7528;&#x4E86;&#x8FD9;&#x4E2A;&#x8FC7;&#x65F6;&#x7684;&#x7C7B;&#x578B;&#x6216;&#x8005;&#x6210;&#x5458;&#xFF0C;&#x867D;&#x7136;&#x7EE7;&#x627F;&#x6216;&#x8005;&#x8986;&#x76D6;&#x540E;&#x7684;&#x7C7B;&#x578B;&#x6216;&#x8005;&#x6210;&#x5458;&#x5E76;&#x4E0D;&#x662F;&#x88AB;&#x58F0;&#x660E;&#x4E3A;@Deprecated&#xFF0C;&#x4F46;&#x7F16;&#x8BD1;&#x5668;&#x4ECD;&#x7136;&#x8981;&#x62A5;&#x8B66;&#x3002;
</code></pre><h3 id="3suppresswarnings">3.@SuppressWarnings</h3>
<pre><code> SuppressWarning&#x4E0D;&#x662F;&#x4E00;&#x4E2A;&#x6807;&#x8BB0;&#x7C7B;&#x578B;&#x6CE8;&#x89E3;&#x3002;&#x5B83;&#x6709;&#x4E00;&#x4E2A;&#x7C7B;&#x578B;&#x4E3A;String[]&#x7684;&#x6210;&#x5458;&#xFF0C;&#x8FD9;&#x4E2A;&#x6210;&#x5458;&#x7684;&#x503C;&#x4E3A;&#x88AB;&#x7981;&#x6B62;&#x7684;&#x8B66;&#x544A;&#x540D;&#x3002;&#x5BF9;&#x4E8E;javac&#x7F16;&#x8BD1;&#x5668;&#x6765;&#x8BB2;&#xFF0C;&#x88AB;-Xlint&#x9009;&#x9879;&#x6709;&#x6548;&#x7684;&#x8B66;&#x544A;&#x540D;&#x4E5F;&#x540C;&#x6837;&#x5BF9;@SuppressWarings&#x6709;&#x6548;&#xFF0C;&#x540C;&#x65F6;&#x7F16;&#x8BD1;&#x5668;&#x5FFD;&#x7565;&#x6389;&#x65E0;&#x6CD5;&#x8BC6;&#x522B;&#x7684;&#x8B66;&#x544A;&#x540D;&#x3002;
</code></pre><p>&#x3000;&#x3000;@SuppressWarnings(&quot;unchecked&quot;)</p>
<hr>
<h2 id="&#x56DB;&#x3001;spring&#x5E38;&#x7528;&#x6CE8;&#x89E3;">&#x56DB;&#x3001;Spring&#x5E38;&#x7528;&#x6CE8;&#x89E3;</h2>
<footer class="page-footer"><span class="copyright">Copyright &#xA9; tgor.top 2019 all right reserved&#xFF0C;powered by Gitbook</span><span class="footer-modification">&#x8BE5;&#x6587;&#x4EF6;&#x4FEE;&#x8BA2;&#x65F6;&#x95F4;&#xFF1A;
2020-04-23 15:32:53
</span></footer>
<script>console.log("plugin-popup....");document.onclick = function(e){ e.target.tagName === "IMG" && window.open(e.target.src,e.target.src)}</script><style>img{cursor:pointer}</style>
                                
                                </section>
                            
    </div>
    <div class="search-results">
        <div class="has-results">
            
            <h1 class="search-results-title"><span class='search-results-count'></span> results matching "<span class='search-query'></span>"</h1>
            <ul class="search-results-list"></ul>
            
        </div>
        <div class="no-results">
            
            <h1 class="search-results-title">No results matching "<span class='search-query'></span>"</h1>
            
        </div>
    </div>
</div>

                        </div>
                    </div>
                
            </div>

            
                
                <a href="HashMap源码分析.html" class="navigation navigation-prev " aria-label="Previous page: JDK源码分析HashMap">
                    <i class="fa fa-angle-left"></i>
                </a>
                
                
                <a href="Timsort排序算法.html" class="navigation navigation-next " aria-label="Next page: Timsort排序算法">
                    <i class="fa fa-angle-right"></i>
                </a>
                
            
        
    </div>

    <script>
        var gitbook = gitbook || [];
        gitbook.push(function() {
            gitbook.page.hasChanged({"page":{"title":"Java注解","level":"1.10.7","depth":2,"next":{"title":"Timsort排序算法","level":"1.10.8","depth":2,"path":"Java-Base/Timsort排序算法.md","ref":"Java-Base/Timsort排序算法.md","articles":[]},"previous":{"title":"JDK源码分析HashMap","level":"1.10.6","depth":2,"path":"Java-Base/HashMap源码分析.md","ref":"Java-Base/HashMap源码分析.md","articles":[]},"dir":"ltr"},"config":{"plugins":["chapter-fold","splitter","tbfed-pagefooter","page-toc-button","-search","search-pro","popup","back-to-top-button","code","copy-code-button"],"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"pluginsConfig":{"tbfed-pagefooter":{"copyright":"Copyright &copy tgor.top 2019","modify_label":"该文件修订时间：","modify_format":"YYYY-MM-DD HH:mm:ss"},"chapter-fold":{},"splitter":{},"search-pro":{"cutWordLib":"nodejieba","defineWord":["Gitbook Use"]},"popup":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"code":{"copyButtons":true},"fontsettings":{"theme":"sepia","family":"serif","size":1},"highlight":{},"page-toc-button":{"maxTocDepth":2,"minTocSize":2},"back-to-top-button":{},"copy-code-button":{},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"theme":"default","author":"tgor","pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"variables":{},"title":"tgor note","gitbook":"*","description":"tgor生活工作记录"},"file":{"path":"Java-Base/Java注解.md","mtime":"2020-04-23T07:32:53.270Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2020-04-29T08:43:24.127Z"},"basePath":"..","book":{"language":""}});
        });
    </script>
</div>

        
    <script src="../gitbook/gitbook.js"></script>
    <script src="../gitbook/theme.js"></script>
    
        
        <script src="../gitbook/gitbook-plugin-chapter-fold/chapter-fold.js"></script>
        
    
        
        <script src="../gitbook/gitbook-plugin-splitter/splitter.js"></script>
        
    
        
        <script src="../gitbook/gitbook-plugin-page-toc-button/plugin.js"></script>
        
    
        
        <script src="../gitbook/gitbook-plugin-search-pro/jquery.mark.min.js"></script>
        
    
        
        <script src="../gitbook/gitbook-plugin-search-pro/search.js"></script>
        
    
        
        <script src="../gitbook/gitbook-plugin-back-to-top-button/plugin.js"></script>
        
    
        
        <script src="../gitbook/gitbook-plugin-code/plugin.js"></script>
        
    
        
        <script src="../gitbook/gitbook-plugin-copy-code-button/toggle.js"></script>
        
    
        
        <script src="../gitbook/gitbook-plugin-lunr/lunr.min.js"></script>
        
    
        
        <script src="../gitbook/gitbook-plugin-lunr/search-lunr.js"></script>
        
    
        
        <script src="../gitbook/gitbook-plugin-sharing/buttons.js"></script>
        
    
        
        <script src="../gitbook/gitbook-plugin-fontsettings/fontsettings.js"></script>
        
    

    </body>
</html>

